﻿using System;
using System.Runtime.Serialization;
using NCMIS.ObjectModel.MetaData;

namespace NCMIS.AccessControl
{
    /// <summary>
    /// Represents an <see cref="NCMIS.AccessControl.AccessControlList"/> with the "exact" flag. Intended use is as a
    /// repository return type.
    /// </summary>
    [DataContract(Namespace = CmisNs.Cmism)]
    public class Acl
    {
        /// <summary>
        /// The wrapped instance of <see cref="NCMIS.AccessControl.AccessControlList"/>.
        /// </summary>
        [DataMember(Name = "ACL")]
        public AccessControlList @AccessControlList
        {
            get;
            set;
        }

        /// <summary>
        /// Indicates that the ACL [returned] fully descibes the permission for this object, i.e. there are no
        /// other security constraints applied to this object.
        /// </summary>
        [DataMember(Name = "exact")]
        public bool Exact
        {
            get;
            set;
        }
    }
}
